package com.mapproject.industrymap.controller;

import com.mapproject.industrymap.service.DataShareService;
import com.mapproject.industrymap.service.SysAutoPublishService;
import com.mapproject.industrymap.utils.ReturnValue;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/share")
public class DataShareController {
    @Autowired
    DataShareService dataShareService;

    @RequestMapping("/personal")
    public ReturnValue dataSharePersonal(@RequestParam(value = "layername")String layername){
        return dataShareService.sharePersonalData(layername);
    }
    @RequestMapping("/delpersonal")
    public ReturnValue dataDelPersonal(@RequestParam(value = "layername")String layername){
        return dataShareService.delPersonalData(layername);
    }
}
